package com.liuzihao.cloudLzhConsumer.service;

import com.liuzihao.cloudLzhConsumer.service.impl.PaymentServiceImpl;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @Author: Liuzihao
 * @Description:
 * @Date Created in 2022-01-25 21:29
 * @Modified By:
 */
@FeignClient(value = "CloudPaymentHystrix",fallback = PaymentServiceImpl.class)
@Component
public interface PaymentService {
    @GetMapping("payment/hystrix/ok/{id}")
    String paymentInfo_OK(@PathVariable("id") Long id);
    @GetMapping("payment/hystrix/timeout/{id}")
    String paymentInfo_TimeOut(@PathVariable("id") Long id);
}
